package com.pcbly.web.persistence.user;

import java.util.List;
import java.util.Map;

import com.pcbly.web.bean.system.AuthorityBean;
import com.pcbly.web.bean.system.GroupBean;
import com.pcbly.web.bean.user.UserBean; 
import com.pcbly.web.persistence.BaseDao;

public interface UserDao extends BaseDao<UserBean> {

	UserBean findUserBeanByUserAndPasswd(String user, String passwd)
			throws Exception;

	UserBean getUserByLoginName(String user) throws Exception;

	List<AuthorityBean> findAuthByUserBean(UserBean user) throws Exception;

	List<UserBean> findUsersByAuthorityBean(AuthorityBean permi)
			throws Exception;

	List<UserBean> findBy(Map<String, String> filter) throws Exception;

	UserBean getUserBeanById(String id) throws Exception;
	
	UserBean updateUserBean(UserBean user)throws Exception;
	
	UserBean saveUserBean(UserBean user)throws Exception;
	
	List<GroupBean> findGroupBeanByUserId(String id) throws Exception;

	List<UserBean> findUserBeanByGroupId(String id) throws Exception; 
	
	List<UserBean> findUserBeanByName(String name) throws Exception;
}
